C1Tiles Task-Based Help > Binding to a Collection of Items |
You can show more than just two alternating items in a C1SlideTile control. By using the ContentSource property you can provide a collection of any number of items that the control will flip through. Define the ContentTemplate (and optionally the AlternateContentTemplate) to define the appearance of the bound content.
XAML |
Copy Code
|
---|---|
<c1:C1SlideTile Header="Photos" ContentSource="{Binding Items}"> <c1:C1SlideTile.ContentTemplate> <DataTemplate> <Grid> <TextBlock Text="{Binding Author}" Foreground="White" VerticalAlignment="Top" Margin="4,2,0,2"/> <Image Source="{Binding Thumbnail}" Stretch="UniformToFill" Margin="24, 24, 1, 1"/> </Grid> </DataTemplate> </c1:C1SlideTile.ContentTemplate> </c1:C1SlideTile> |